﻿using System.Net;

namespace Skybot.BaseSocket
{
    public class SocketClientEventArgs
    {
        /// <summary>
        /// 消息数据
        /// </summary>
        public byte[] Message { get; set; }


        /// <summary>
        /// 事件
        /// </summary>
        public EventMode EventMode { get; set; }


        /// <summary>
        /// 事件状态
        /// </summary>
        public EventError EventError { get; set; }


        /// <summary>
        /// 连接节点
        /// </summary>
        public EndPoint EndPoint { get; set; }
    }


    public enum EventMode
    {
        /// <summary>
        /// 连接事件
        /// </summary>
        ConnectEvent=  1,

        /// <summary>
        /// 写事件
        /// </summary>
        WriteEvent = 2,

        /// <summary>
        /// 读事件
        /// </summary>
        ReadEvent =3
    }

    /// <summary>
    /// 事件状态
    /// </summary>
    public enum EventError
    {
        /// <summary>
        /// 成功
        /// </summary>
        Success = 1,

        /// <summary>
        /// 失败
        /// </summary>
        Failed = 2
    }
}
